<?php
/*
 * Copyright (c) 2017-2025 Tencent. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
namespace TencentCloud\Mdp\V20200527\Models;
use TencentCloud\Common\AbstractModel;

/**
 * SourceInfo.
 *
 * @method string getName() Obtain name.
 * @method void setName(string $Name) Set name.
 * @method string getType() Obtain The source type distinguishes between live broadcast and on-demand Vod.
 * @method void setType(string $Type) Set The source type distinguishes between live broadcast and on-demand Vod.
 * @method array getPackageConf() Obtain Source configuration.
 * @method void setPackageConf(array $PackageConf) Set Source configuration.
 * @method string getId() Obtain ID.
 * @method void setId(string $Id) Set ID.
 * @method integer getCreateTime() Obtain Create timestamp.
 * @method void setCreateTime(integer $CreateTime) Set Create timestamp.
 * @method integer getUpdateTime() Obtain Update timestamp.
 * @method void setUpdateTime(integer $UpdateTime) Set Update timestamp.
 * @method string getRegion() Obtain Region.
 * @method void setRegion(string $Region) Set Region.
 */
class SourceInfo extends AbstractModel
{
    /**
     * @var string name.
     */
    public $Name;

    /**
     * @var string The source type distinguishes between live broadcast and on-demand Vod.
     */
    public $Type;

    /**
     * @var array Source configuration.
     */
    public $PackageConf;

    /**
     * @var string ID.
     */
    public $Id;

    /**
     * @var integer Create timestamp.
     */
    public $CreateTime;

    /**
     * @var integer Update timestamp.
     */
    public $UpdateTime;

    /**
     * @var string Region.
     */
    public $Region;

    /**
     * @param string $Name name.
     * @param string $Type The source type distinguishes between live broadcast and on-demand Vod.
     * @param array $PackageConf Source configuration.
     * @param string $Id ID.
     * @param integer $CreateTime Create timestamp.
     * @param integer $UpdateTime Update timestamp.
     * @param string $Region Region.
     */
    function __construct()
    {

    }

    /**
     * For internal only. DO NOT USE IT.
     */
    public function deserialize($param)
    {
        if ($param === null) {
            return;
        }
        if (array_key_exists("Name",$param) and $param["Name"] !== null) {
            $this->Name = $param["Name"];
        }

        if (array_key_exists("Type",$param) and $param["Type"] !== null) {
            $this->Type = $param["Type"];
        }

        if (array_key_exists("PackageConf",$param) and $param["PackageConf"] !== null) {
            $this->PackageConf = [];
            foreach ($param["PackageConf"] as $key => $value){
                $obj = new SourcePackageConf();
                $obj->deserialize($value);
                array_push($this->PackageConf, $obj);
            }
        }

        if (array_key_exists("Id",$param) and $param["Id"] !== null) {
            $this->Id = $param["Id"];
        }

        if (array_key_exists("CreateTime",$param) and $param["CreateTime"] !== null) {
            $this->CreateTime = $param["CreateTime"];
        }

        if (array_key_exists("UpdateTime",$param) and $param["UpdateTime"] !== null) {
            $this->UpdateTime = $param["UpdateTime"];
        }

        if (array_key_exists("Region",$param) and $param["Region"] !== null) {
            $this->Region = $param["Region"];
        }
    }
}
